package com.lvmama.client.rhino;

import com.lvmama.common.result.Result;
import com.lvmama.pojo.entity.rhino.product.ProductDetail;
import com.lvmama.pojo.entity.rhino.searchanalysis.FlowSearchStation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import java.util.List;
import java.util.Map;

@FeignClient("rhino-web-service")
@RequestMapping("${server.servlet.context-path}")
public interface ProductClient {


    @RequestMapping(method = RequestMethod.POST, value = "/product/productDetail")
    Result<List<FlowSearchStation>> productDetail();

    @RequestMapping(method = RequestMethod.POST, value = "/product/productDetailChartData")
    Result<Map<String, Object>> productDetailChartData(@RequestBody ProductDetail productDetail);

    @RequestMapping(method = RequestMethod.POST, value = "/product/trackProduct")
    Result<Map<String, Object>> trackProduct(@RequestBody ProductDetail productDetail);

    @RequestMapping(method = RequestMethod.POST, value = "/product/fiftyProductList")
    Result<Map<String, Object>> getFiftyProductList(@RequestBody ProductDetail productDetail);

}
